const delay = (ms = 3000) =>
  new Promise(resolve => {
    setTimeout(resolve, ms)
  })

// pv统计
module.exports = app => {
  app.get('/soap/filmDetailPv/:id', async (req, res) => {
    // res.send('1111 == ' + req.ip + req.headers['user-agent'])
    // await delay()
    res.send({
      code: 0,
      msg: 'ok',
      data: {
        pv: Date.now(),
        uv: 200,
        ip: 10
      }
    })
  })
}
